// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import {postRequest, getRequest} from './tools/request'
import BaiduMap from 'vue-baidu-map'
import './assets/css/reset.css'
import './assets/css/common.css'
import zoom from './assets/scripts/tool/zoom'
import VeHistogram from 'v-charts/lib/histogram.common'
import VeLine from 'v-charts/lib/line.common'
import VePie from 'v-charts/lib/pie.common'
zoom()
window.addEventListener('resize', zoom)
Vue.config.productionTip = false
Vue.prototype.postRequest = postRequest
Vue.prototype.getRequest = getRequest
Vue.use(BaiduMap, {
  // ak 是在百度地图开发者平台申请的密钥 详见 http://lbsyun.baidu.com/apiconsole/key */
  ak: 'Ih6Gfsl6ixZoOCbIVFo2ZArAoC8qgn5X'
})
Vue.component(VeHistogram.name, VeHistogram)
Vue.component(VeLine.name, VeLine)
Vue.component(VePie.name, VePie)
/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  template: '<App/>',
  components: {App}
})
